import Login from './views/Login.vue'
import NotFound from './views/404.vue'
import Home from './views/Home.vue'
import DepartmentPage from './views/org/DepartmentPage.vue'
import Table from './views/nav1/Table.vue'
import Page4 from './views/nav2/Page4.vue'
import Page5 from './views/nav2/Page5.vue'
import Page6 from './views/nav3/Page6.vue'
import echarts from './views/charts/echarts.vue'
import employeePage from './views/org/employeePage'
import Config from "./views/system/Config";
import Dictionary from "./views/system/Dictionary";
import DictionaryItem from "./views/system/DictionaryItem";
import ProductType from "./views/product/ProductType";
import Product from "./views/product/Product";
import ImageUpAndDown from "./views/images/ImageUpAndDown"
let routes = [
    {
        path: '/login',
        component: Login,
        name: '',
        hidden: true
    },
    {
        path: '/404',
        component: NotFound,
        name: '',
        hidden: true
    },
    {
        path: '/',
        component: Home,
        name: 'Charts',
        iconCls: 'fa fa-bar-chart',
        leaf: true,
        children: [
            { path: '/', component: echarts, name: '首页' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '组织机构',
        iconCls: 'el-icon-message',//图标样式class
        children: [
            { path: '/department', component: DepartmentPage, name: '部门管理' },
            { path: '/employee', component: employeePage, name: '员工管理' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '系统管理',
        iconCls: 'fa fa-id-card-o',
        children: [
            { path: '/config', component: Config, name: '系统配置' },
            { path: '/dictionary', component: Dictionary, name: '数据字典' },
            { path: '/dictionaryitem', component: DictionaryItem, name: '字典详细' }
        ]
    },
    {
        path: '/',
        component: Home,
        name: '产品管理',
        iconCls: 'fa fa-id-card-o',
        children: [
            { path: '/productType', component: ProductType, name: '产品类型' },
            { path: '/product', component: Product, name: '产品列表' },
        ]
    },{
        path: '/',
        component: Home,
        name: '图片的上传和下载',
        children: [
            {path: '/upload',component: ImageUpAndDown, name: '图片的上传'}
        ]
    },
    {
        path: '*',
        hidden: true,
        redirect: { path: '/404' }
    }
];

export default routes;